home *** CD-ROM | disk | FTP | other *** search
/ Adobe Graphics & Publishing SDK 1996 December / Adobe Graphics & Publishing SDK 1996 December.iso / mac / PageMaker 6.5 SDK Mac / SourceCode / PageMakerClassLibrary / Commands / PPaintWindow.cpp < prev    next >
C/C++ Source or Header  |  1996-08-15  |  942b  |  36 lines

  1. /*
  2.  *--- PPaintWindow.cpp ----------------------------------------------------
  3.  * Copyright (c) 1995-96 Adobe Systems Incorporated.  All rights reserved.
  4.  * Created on Thu, Oct 12, 1995 @ 10:48 PM by Paul Ferguson.
  5.  *
  6.  * Description:  For notes about this class, refer to the
  7.  * PCL documentation file PPaintWindow.html
  8.  *-------------------------------------------------------------------------
  9.  */
  10.  
  11.  
  12. #include "PPaintWindow.h"
  13. #include "PCommand.h"
  14.  
  15. PPaintWindow::PPaintWindow(long theWindow)
  16. {
  17.     PCommand command(pm_paintwindow, theWindow);
  18.  
  19. #ifdef MACINTOSH
  20.     if (theWindow)        // you will have to provide this yourself.
  21.     {
  22.         GrafPtr    savedPort;
  23.         
  24.         GetPort(&savedPort);
  25.         SetPort((GrafPtr) theWindow);
  26.         BeginUpdate((GrafPtr) theWindow);
  27.         // Note:  May need to put InvalRect() trap in here... Should check.
  28.         
  29.         EndUpdate((GrafPtr) theWindow);
  30.         SetPort(savedPort);
  31.     }
  32. #endif
  33. }
  34.  
  35. // end of PPaintWindow.cpp
  36.